<include file="Public/header"/>
<body>      
<div id="tbh5v0">
<div class="user_com">
<include file="Public/uer_topnav"/>

<div class="endorse_hend">
	<p>{$tpshop_config['distribut_name']}：我发展的{$_GET['level']}级（{$count}）人</p>
</div>

<div class="Wallet">
	<div class="endorse_dyr">
		<form action="{:U('Distribut/lower_list',array('level'=>$_GET['level']))}" method="post" id="filter_form">
			<input class="endor_text" type="text" name="q" />
			<input class="endor_but" type="button"  onClick="ajax_search();" value="搜索"/>
		</form>
	</div>
	<div class="endorse_dyr bg_gray" id="ajax_return">
		<foreach name="list" item="v" > 
            <div class="endorse_num">
                <div class="hend_endor">
                    <img src="{$v['head_pic']|default="__STATIC__/images/hend_none.png"}" width="60" height="60" />
                </div>
                <div class="sec_endor">
                    <p>昵称：<span>{$v['nickname']}</span></p>
                    <p>电话：<span>{$v['mobile']|default="--"}</span></p>
                    <p>加盟时间：<span>{$v['reg_time']|date="Y-m-d",###}</span></p>
                    <p>会员ID：<span>{$v['user_id']}</span></p>
                </div>               
            </div>
		</foreach> 
          <empty name="list">
		      <div id="list_0_0" class="font12">您现在还没数据！</div>
          </empty>
	</div>
	    <notempty name="list">
	          <p style="text-align: center;" id="getmore"><a href="javascript:void(0)" onClick="ajax_sourch_submit()">点击加载更多</a></p>        
        </notempty>  
</div>


</div>
<include file="Public/footer"/>
</div>
<include file="Public/footer_nav"/>
</body>
<script>

var  page = 1;
 /*** ajax 提交表单 查询订单列表结果*/  
 function ajax_sourch_submit()
 {	 	 	 
        page += 1;
		$.ajax({
			type : "POST",			
			url:"/index.php?m=Mobile&c=Distribut&a=lower_list&level={$_GET['level']}&is_ajax=1&p="+page,//+tab,
			data : $('#filter_form').serialize(),// 你的formid 搜索表单 序列化提交
			success: function(data)
			{
				if($.trim(data) == '')
					$('#getmore').hide();
				else{
				    $("#ajax_return").append(data);
					$('#getmore').show();
				}
			}
		}); 
 } 
  /*点击搜索按钮*/ 
  function ajax_search(){	 
	 page = 0;
	 $('#ajax_return').html('');
	 ajax_sourch_submit();	 
 }
</script>
</html>